/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package grupb.upf.XMLObjects.impl;

import grupb.upf.XMLObjects.MetadataDC;
import grupb.upf.XMLObjects.Tagging;
import java.io.Serializable;

/**
 * <p>This class implements the management of the data associated to a photo.
 * </p>
 *
 * @version    0.0.1-SNAPSHOT
 * @author     Group B
 */
public final class Photo implements grupb.upf.XMLObjects.Photo, Serializable {

    /**
     * The serialVersionUID is created to be able to serialize this class, it's
     * necessary because it will be sent.
     */
    private static final long serialVersionUID = 1L;
    /**
     * The id of the picture.
     */
    private int id;
    /**
     * The URL where the picture is stored.
     */
    private String url;
    /**
     * The metadata of the photo.
     */
    private MetadataDC metadata;
    /**
     * The tags of hte photo.
     */
    private Tagging tags;
    /**
     * This methods set the id of a photo.
     * @param photoID The photo id.
     */
    @Override
    public void setID(final int photoID) {
        this.id = photoID;
    }
    /**
     * This method returns the id of a photo.
     * @return The photo id.
     */
    @Override
    public int getID() {
        return this.id;
    }
    /**
     * This method returns the URL of a photo.
     * @param photoURL The url of the photo
     */
    @Override
    public void setURL(final String photoURL) {
        this.url = photoURL;
    }
    /**
     * This method returns the URL of a photo.
     * @return The URL of the photo.
     */
    @Override
    public String getURL() {
        return this.url;
    }
    /**
     * This method returns the metadatada of a photo.
     * @param photoMeta The metadata of the photo.
     */
    @Override
    public void setMetadataDC(final MetadataDC photoMeta) {
        this.metadata = photoMeta;
    }
    /**
     * This method returns the metada of a photo.
     * @return The photo metadata
     */
    @Override
    public MetadataDC getMetadataDC() {
        return this.metadata;
    }
    /**
     * This method allows us to set the tag of a photo.
     * @param photoTags The tags of the photo
     */
    @Override
    public void setTags(final Tagging photoTags) {
        this.tags = photoTags;
    }
    /**
     * This method returns the tags of a photo.
     * @return The tags of the photo
     */
    @Override
    public Tagging getTags() {
        return this.tags;
    }
}
